package com.base.common.persistent.dao;

import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.base.common.persistent.model.Message;
import com.cjy.common.annotation.MyBatisRepository;

/**
 * 通知信息dao
 * 
 * @author kat.luhongkai
 *
 */
@MyBatisRepository
public interface MessageMapper {

	/**
	 * 
	 * @param start
	 * @param end
	 * @param categories
	 * @param compoundsId
	 * @return
	 */
	public List<Message> queryMessagesByCategory(
			@Param(value = "start") int start, @Param(value = "end") int end,
			@Param(value = "typeId") int typeId);

	/**
	 * 查询文章类型id根据字段名和小区id
	 * 
	 * @param compoundsId
	 *            小区id
	 * @param field
	 *            字段名
	 * @return
	 */
	public int queryTypeIdByCompoundsIdAndField(
			@Param(value = "compoundsId") int compoundsId,
			@Param(value = "field") String field);

	/**
	 * 测试
	 * 
	 * @return
	 */
	public List<Message> test(@Param(value = "start") int start,
			@Param(value = "end") int end, @Param(value = "typeId") int typeId);
}
